package com.gpsnav.util;
import net.rim.device.api.ui.component.ObjectChoiceField;

public class ResizableChoiceField extends ObjectChoiceField {
    private String[] dccChoices;
   public ResizableChoiceField(String l, String[] c, int i) {
        super(l,c,i);
        dccChoices = c;
    }

    protected void layout(int width, int height)  {
        int w = 1;
        for (int i=0;i<dccChoices.length;i++) {
            int v = getFont().getAdvance(dccChoices.toString());
            w = Math.max(w,v);
        }
//        super.layout(w+3,height);
        super.layout(20,height);
    }
}
